<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>

    <style>
        .greenSty{
            color: green;
        }

        .blueSty{
            color: blue;
        }
    </style>
</head>
<body>
    <script src="https://unpkg.com/vue@next"></script>
    <div id="app">
        <!-- 可以使用表达式 -->
        <span v-bind:class="isChange?greenStyle:blueStyle">哈哈哈哈</span>


    </div>

    <script>
        const vueOption = {
            data(){
                return {
                    isChange: true,
                    greenStyle: 'greenSty',
                    blueStyle: 'blueSty'
                }
            }
        }

        Vue.createApp(vueOption).mount('#app');
    </script>

</body>
</html>
